<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head>
    <TITLE>華信商会(株) 販売管理業務システム</TITLE>
    <link th:href="@{/css/financials.css}" rel="stylesheet" type="text/css">
    <META http-equiv="Content-Type" content="text/HTML; charset=UTF-8">
    <STYLE type="text/css">
        <!-- 原有样式保持不变 -->
        BODY { background-color: #F8F9FB; margin: 0 }
        .style13 { color: #FFFFFF; font-weight: bold }
        .style28 { font-family: "ＭＳ ゴシック"; font-size: 12px }
    </STYLE>
</head>
<body>
<TABLE width="100%" border="0" cellpadding="0" cellspacing="0">
    <!-- 头部保持不变 -->
    <TR>
        <TD height="55" colspan="2">
            <TABLE width=100% height="56" border=0 cellPadding=0 cellSpacing=0>
                <TBODY>
                <TR bordercolor="0">
                    <TD height="49" bgColor=#666666>
                        <TABLE cellSpacing=0 cellPadding=0 width=100 border=0>
                            <TBODY>
                            <TR>
                                <TD><IMG th:src="@{/img/header_logo_rt.gif}" width=1 border=0></TD>
                                <TD><IMG th:src="@{/img/header_logo.gif}" width="185" height="49"></TD>
                                <TD><IMG th:src="@{/img/header_logo_rt.gif}" width=105></TD>
                                <TD><IMG th:src="@{/img/header_title.gif}" width=329></TD>
                            </TR>
                            </TBODY>
                        </TABLE>
                    </TD>
                </TR>
                </TBODY>
            </TABLE>
        </TD>
    </TR>

    <!-- 主体内容 -->
    <TR>
        <TD>
            <DIV class="header3"><BR></DIV>
            <DIV class="bfont" align="left">
                ログイン：<span th:text="${loginUser}">張毅</span>
            </DIV>
            <BR>
            <DIV class="bfont" align="left">
                発注管理－＞発注書作成－＞発注書
            </DIV>
            <HR>
        </TD>
    </TR>

    <!-- 供应商信息 -->
    <TR>
        <TD>
            <TABLE width="100%">
                <TBODY>
                <TR>
                    <TD class="TABLEHeader_staffCol" nowrap width="10%">
                        <span class="datafont">仕入先コード:</span>
                    </TD>
                    <TD class="TABLEBody_staffCol" th:text="${supplierCode}"></TD>
                    <TD class="TABLEHeader_staffCol" width="10%" nowrap>
                        <span class="datafont">仕入先名:</span>
                    </TD>
                    <TD class="TABLEBody_staffCol" th:text="${supplierName}"></TD>
                    <TD class="TABLEHeader_staffCol" width="10%" nowrap>
                </TR>
                <TR>
                    <TD class="TABLEHeader_staffCol" nowrap width="10%">
                        <span class="datafont">発注コード:</span>
                    </TD>
                    <TD class="TABLEBody_staffCol" th:text="${randomCode}"></TD>
                    <TD class="TABLEHeader_staffCol" width="10%" nowrap>
                        <span class="datafont">発注日付:</span>
                    </TD>
                    <TD class="TABLEBody_staffCol" th:text="${formattedDate}"></TD>
                </TR>
                </TBODY>
            </TABLE>
        </TD>
    </TR>

    <!-- 商品明细 -->
    <TR>
        <TD>
            <TABLE width="800" border="1" cellpadding="1" cellspacing="1" bordercolor="#000000">
                <TR>
                    <TD width="6%"><DIV align="center" class="datafont">項番</DIV></TD>
                    <TD width="13%"><DIV align="center" class="datafont">商品コード</DIV></TD>
                    <TD width="26%"><DIV align="center" class="datafont">商品名</DIV></TD>
                    <TD width="13%"><DIV align="center" class="datafont">単価</DIV></TD>
                    <TD width="8%"><DIV align="center" class="datafont">単位</DIV></TD>
                    <TD width="13%"><DIV align="center" class="datafont">数量</DIV></TD>
                </TR>

                <!-- 动态商品数据 -->
                <tr th:each="product, stat : ${selectedProducts}">
                    <TD align="middle" th:text="${stat.index + 1}">1</TD>
                    <TD align="left" th:text="${product.M00201}">XXXXX</TD>
                    <TD align="left" th:text="${product.M00202}">商品名</TD>
                    <TD align="right" th:text="${#numbers.formatDecimal(product.M00205, 1, 0, 'COMMA')}">0</TD>
                    <TD align="middle" th:text="${product.M00204}">単位</TD>
                    <TD align="right" th:text="${product.M00209}">0</TD>
                </tr>

                <!-- 无数据提示 -->
                <tr th:if="${#lists.isEmpty(selectedProducts)}">
                    <td colspan="6" align="center">選択された商品がありません</td>
                </tr>
            </TABLE>
        </TD>
    </TR>

    <!-- 底部 -->
    <TR>
        <TD height="10" colspan="2">
            <TABLE width=100% border=0 cellpadding=0 cellspacing=0 bgcolor="#666666">
                <TBODY>
                <TR>
                    <TD align="right">
                        <input type="button" value="<- 戻る"
                               th:onclick="|window.location.href='@{/PR30101}'|">
                    </TD>
                </TR>
                <TR>
                    <TD bgcolor="#000000">
                        <span class="style13">
                            <span class="style28">c2008 大連華信計算機新技術培訓中心. すべての知る権利を保留</span>
                        </span>
                    </TD>
                </TR>
                </TBODY>
            </TABLE>
        </TD>
    </TR>
</TABLE>
</body>
</html>